package hospital.serviceImpl;

import hospital.dao.LegalDao;
import hospital.model.AuditDetailModel;
import hospital.model.EmpInfoModel;
import hospital.service.LegalService;

import java.util.List;

public class LegalServiceImpl implements LegalService {
	private LegalDao legalDao;

	@Override
	public List<EmpInfoModel> getDocResult(long userId, String firstname, String lastname) {
		return legalDao.selectGetDocResult(userId, firstname, lastname);
	}

	public LegalDao getLegalDao() {
		return legalDao;
	}

	public void setLegalDao(LegalDao legalDao) {
		this.legalDao = legalDao;
	}

	@Override
	public List<AuditDetailModel> getAuditDetailList(long docId) {
		return legalDao.selectGetAuditDetailList(docId);
	}

	@Override
	public List<AuditDetailModel> searchAudit(long docId, long patientId, long recordTimeStart, long recordTimeEnd) {
		return legalDao.selectSearchAudit(docId, patientId, recordTimeStart, recordTimeEnd);
	}

	@Override
	public String checkPassword() {
		return legalDao.selectCheckPassword();
	}

	@Override
	public boolean changePassword(String password) {
		return legalDao.updateChangePassword(password);
	}
	
	
}
